#pragma once

#include "GameObject.h"

class Tile;

class Obstacle : public GameObject {
protected:
	bool m_blocking;
	Tile* m_tile;
public:
	Obstacle(GenericType type);
	Obstacle(GenericType type, std::ifstream& file);
	virtual ~Obstacle();
	bool isBlocking();
	void setTile(Tile* tile);
	Tile* getTile() const;
	virtual void logDetails(TextLog& log) const;
	std::string getColoredName() const;
	std::string getColoredBasicName() const;
	virtual void save(std::ofstream& file) const;
};

inline bool Obstacle::isBlocking() {return m_blocking;}
inline void Obstacle::setTile(Tile* tile) {m_tile = tile;}
inline Tile* Obstacle::getTile() const {return m_tile;}